]> permondes.de Git - Analog_Engine.git/blob - scripts/TP1 10.30 Linear Molecule.LACE
Focus on potential fields
[Analog_Engine.git] / scripts / TP1 10.30 Linear Molecule.LACE
1 # TP1 10.30 Linear Molecule
2 # In a linear molecule of symmetric construction of type A-B-A the atoms are harmonically coupled and are performing small oscillations around the equilibrium positions.
3
4 # s1'' = -omega0^2*s1 + omega0^2*s2
5 # s2'' = -my (-omega0^2*s1 + omega0^2*s2 + omega0^2*s2 - omega0^2*s3)
6 # s3'' = omega0^2*s2 - omega0^2*s3
7
8 # NB: all integrators have to run with 100 nF capacitance, i.e. SLOW mode
9
10 # the following integrator has to be built up manually as THAT only has 5 integrators and we need 6
11 # iintegrate -s2' -> s2
12 define openamp (variable) -> result
13 isum (variable) -> result
14 connect (FB) -> GND
15
16 define iintegrate6 (variable) -> integral
17 openamp variable -> integral
18 connect SJ -> cp
19 capacitor.100nF (integral) -> cp
20 # this capacitance requires SLOW settings on all other capacitors. Better use an external 1 nF capacitor.
21
22 alias coefficient.1 -> coefficient.omega0^2_1 # omega0^2 for s1
23 alias coefficient.2 -> coefficient.omega0^2_2 # omega0^2 for s2 # same as omega0^2_1
24 alias coefficient.3 -> coefficient.omega0^2_3 # omega0^2 for s3 # same as omega0^2_1
25 alias coefficient.4 -> coefficient.my
26 coefficient.5 (-1) -> -s1_0 # initial position of s1
27 coefficient.6 (-1) -> -s3_0 # initial position of s3
28 # initial positon of s2, the central mass, is set to 0
29
30 iintegrate -omega0^2_1*s1, omega0^2_2*s2 -> -s1' # input is s1''
31 iintegrate -s1' -> s1
32 IC: -s1_0
33 invert s1 -> -s1
34 coefficient.omega0^2_1 (-s1) -> -omega0^2_1*s1
35
36 iintegrate -my*bracket -> -s2' # input is s2''
37 iintegrate6 -s2' -> s2
38 coefficient.omega0^2_2 (s2) -> omega0^2_2*s2
39 isum -omega0^2_1*s1, omega0^2_2*s2, omega0^2_2*s2, -omega0^2_3*s3 -> -bracket
40 coefficient.my (-bracket) -> -my*bracket
41
42 iintegrate omega0^2_2*s2, -omega0^2_3*s3 -> -s3' # input is s3''
43 iintegrate -s3' -> s3
44 IC: -s3_0
45 invert s3 -> -s3
46 coefficient.omega0^2_3 (-s3) -> -omega0^2_3*s3
47
48 output s1 -> out.x
49 output s2 -> out.y
50 output s3 -> out.z
51